package com.ziyun.erp.modules.member.dao;

import com.ziyun.erp.modules.member.entity.UserShareEntity;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;

/**
 * 用户分享家信息表
 * 
 * @author guizhao
 * @email ...
 * @date 2018-08-29 10:59:35
 */
public interface UserShareDao extends BaseMapper<UserShareEntity> {

    void reject(@Param("amount") BigDecimal amount, @Param("userId") Integer userId);

    void pay(@Param("amount") BigDecimal amount, @Param("userId") Integer userId);

    int updateCommissionAdd(@Param("userId") Integer userId, @Param("commission") BigDecimal commission,
                            @Param("usableCommission") BigDecimal usableCommission);

    int updateCommissionThawing(@Param("userId") Integer userId, @Param("commission")BigDecimal commission,
                                @Param("usableCommission")BigDecimal usableCommission);
}
